package library.client.domain.query;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDate;

/**
 * 
 *
 */
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "图书分页查询")
public class BookPageQuery extends PageQuery{

    @ApiModelProperty("图书id")
    private Integer id;

    @ApiModelProperty("图书名")
    private String title;

    @ApiModelProperty("作者姓名")
    private String author;

    @ApiModelProperty("国际标准书号")
    private String isbn;

    @ApiModelProperty("图书分类")
    private String category;

    @ApiModelProperty("最小出版日期")
    @DateTimeFormat(pattern = "yyyy-M-d")
    private LocalDate minPublishedDate;

    @ApiModelProperty("最大出版日期")
    @DateTimeFormat(pattern = "yyyy-M-d")
    private LocalDate maxPublishedDate;
}
